package com.xiaoc.bulldozer.common.service;

import java.util.List;

import com.xiaoc.bulldozer.common.dto.AppointmentDto;
import com.xiaoc.bulldozer.common.dto.AppointmentQueryDto;
import com.xiaoc.bulldozer.common.model.Appointment;

/**
 * Appointment Service 接口
 * 
 * @author wj
 * 
 * @date 2019-04-29 09:49:19
 */
public interface AppointmentService {

    /**
     * 根据条件查询Appointment数量
     
     * @param AppointmentQueryDto
     *
     * @return 满足查询条件的记录数量
     */
    public Integer getAppointmentCountByCondition(AppointmentQueryDto appointmentQueryDto);
    
    /**
     * 根据条件分页查询Appointment列表
     *
     * @param AppointmentQueryDto
     *
     * @return 满足查询条件的Appointment列表
     */
    public List<Appointment> getAppointmentListByCondition(AppointmentQueryDto appointmentQueryDto);
    
    /**
     * 根据Id获取Appointment
     * 
     * @param id
     *
     * @return Appointment对象
     */
    public Appointment getAppointmentById(Integer id);

    /**
     * 获取所有Appointment列表
     * 
     * @return Appointment列表
     */
    public List<Appointment> getAllAppointmentList();

    /**
     * 新增Appointment
     * 
     * @param appointment
     *
     * @return void
     */
    public void save(Appointment appointment);

    /**
     * 更新Appointment
     * 
     * @param appointment
     *
     * @return void
     */
    public void update(Appointment appointment);

    /**
     * 根据Id删除Appointment
     * 
     * @param id
     *
     * @return void
     */
    public void deleteById(Integer id);


    /**
     * 根据手机号查询预约列表
     *
     * @param phone
     *
     * @return 满足查询条件的Appointment列表
     */
    public List<Appointment> getAppointmentListByPhone(String phone);

    List<AppointmentDto> getMyAppointmentListByPhoneOrAccountId(String phone, Integer accountId);

    Integer  getCountByManagerAccountId(AppointmentQueryDto appointmentQueryDto);

    List<AppointmentDto> getAppointmentListByManagerAccountId(AppointmentQueryDto appointmentQueryDto);

}
